
workspace "StateThread"
	configurations { "Debug", "Release" }
	platforms { "Win32", "Linux" }
	location "build"

filter { "platforms:Win32" }
    system "windows"
    architecture "x32"
	defines { "_WIN32", "WIN32" }
	
filter { "platforms:Linux" }
    system "linux"
    architecture "x64"	
	defines { "LINUX", "linux" ,"POSIX"}
	
filter "configurations:Debug"
	defines { "DEBUG" , "_DEBUG"}
	flags { "Symbols" }
	optimize "Debug"
	
filter "configurations:Release"
	defines { "NDEBUG" }
	optimize "On"
	flags { "OptimizeSpeed", "EnableSSE2" }
	

project "StateThread"
	kind "staticLib"
	language "C++"
	
	includedirs{"./"}
	
	filter { "platforms:Win32" }
		includedirs{"StateThread/windows"}
		files { 
			"StateThread/windows/*.h", 
			"StateThread/windows/*.c",
			"StateThread/windows/extensions/*.h", 
			"StateThread/windows/extensions/*.c",			
		}
		
	filter { "platforms:Linux" }
		includedirs{"StateThread/linux"}
		files { 
			"StateThread/linux/*.h", 
			"StateThread/linux/*.c",
		}
	
project "test"
	kind "ConsoleApp"
	language "C++"
	
	files{
		"test.c"
	}
	links{"StateThread"}
	
	filter { "platforms:Win32" }
		includedirs{"StateThread/windows"}
		links{"ws2_32"}
	filter { "platforms:Linux" }
		includedirs{"StateThread/linux"}
		links{"pthread","rt"}	
	
	
	
	
	